A mail server is a computer that serves as an electronic post office for email. Mail exchanged across networks is passed between mail servers that run software that implements standardized protocols for handling e-mail messages and any media content the messages may contain. A mail server computer runs software that implements a mail transfer agent (MTA) or mail relay. The MTA transfers electronic mail messages from one computer to another using a client-server computer architecture. The MTA implements both the client (sending) and server (receiving) portions of the Simple Mail Transfer Protocol (SMTP).
A Domain Name System (DNS) is a hierarchical distributed naming system for computers, services, or any resource connected to the Internet or a private network. It associates various information with domain names assigned to each of the participating entities. A Domain Name Service translates queries for domain names (which are meaningful to humans) into Internet Protocol (IP) addresses for the purpose of locating computer services and devices worldwide. The DNS associates a mail server to a domain with mail exchanger (MX) resource records containing the domain name of a host providing MTA services. A MX record is a type of resource record in the DNS that specifies a mail server responsible for accepting e-mail messages on behalf of a recipient's domain, and a preference value used to prioritize mail delivery if multiple mail servers are available. The set of MX records of a domain name specifies how e-mail should be routed with SMTP.